from api_v1 import create_app, db, models
from flask_migrate import Migrate, MigrateCommand
from flask_script import Manager


app = create_app("develop")

# 創建Manger對象，管理app
manager = Manager(app)

# 使用Migrate將db,app關聯起來
Migrate(app, db)

# 添加操作命令使用，MigrateC ommand
manager.add_command("db", MigrateCommand)

if __name__ == "__main__":
    manager.run()

    # / favicon.ico
